

void delay();

void main()
{
	int i;
	TRISB=0x00;			// initialiser porten B til utport

	while (1)
	{	
		PORTB=0; 		// slukk alle lys
		delay();
		PORTB.0=1;		// tenn RB0-dioden
		delay();
		PORTB.1=1;		// tenn RB1-dioden
		delay();
		PORTB.2=1;		// tenn RB2-dioden
		delay();
		PORTB.3=1;		// tenn RB3-dioden
		delay();
	}
};


void delay()
{
	uns16 i;
	for (i=0;i<50000;)
	{
		i++;
	}
};